POV-Ray : Newsgroups : povray.beta-test : Height field defects : Height field defects Server Time
29 Jul 2024 06:14:17 EDT (-0400)
  Height field defects  
From: Slime
Date: 1 Feb 2004 03:00:09
Message: <401cb209$1@news.povray.org>
First off, let me thank the POV-Team for including my fix for height field
normals!

However, while checking out whether it got included or not, I noticed
another problem: along the right and upper edges of height fields, the
normals are undefined. I actually discovered this problem back when I was
working with the height field code before, but I guess it got overlooked. In
any case, the normals of the rightmost and topmost vertices of height fields
are not calculated, so seemingly random values from the allocated memory are
used instead. This scene demonstrates the problem:

camera {
  location <.8,1,-.5>
  look_at <.5,0,.5>
}

height_field
{
  function 32, 32 {pattern{bozo scale 1/3}}
  smooth
  scale <2,.5,2>/2
  pigment {rgb 1}
}

light_source {
  <.5,3.5,-.5>*0 + <-1,1,-1>*999
  rgb 1
}

Now, you will get different results than I did, because it's taking
uninitialized data from memory - it's actually different each time you
render. The areas to look at are the rightmost and uppermost parts of the
height field.

If I remember correctly, this problem can be fixed simply by replacing two
less-than signs with less-than-or-equal-to signs in the source code.

By the way: I noticed anti-aliasing was changed so that clipping occurs
after anti-aliasing. (You can see this effect on the edge of the height
field sometimes.) I'll be interested to see how this change turns out. =)

So... anyone care to render my scene and confirm the problem? Thanks =)

 - Slime
 [ http://www.slimeland.com/ ]


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.